libexpr: Include derivation names in the call stack profile#13261
libexpr: Include derivation names in the call stack profile#13261Mic92 merged 3 commits intoNixOS:masterfrom
Conversation
Sometimes the profiler might want to do evaluation (e.g. for getting derivation names). This is not ideal, but is really necessary to make the profiler stack traces useful for end users.
This makes the profiler much more useful by actually distiguishing different derivations being evaluated. This does make the implementation a bit more convoluted, but I think it's worth it.
|
This seems very useful.
Maybe a nicer way to frame and implement this, is as a general way to add data to traces.
and potentially more, e.g. a thunk type that remembers the Doesn't have to all be done in this PR of course, but I feel that by developing this functionality more, it becomes less convoluted. |
That could be done by probably just making Generally I'm not too keen on forcing arbitrary |
Motivation
This makes the profiler much more useful by actually distiguishing
different derivations being evaluated. This does make the implementation
a bit more convoluted, but I think it's worth it.
Example evaluation of `flutter`
$ nix eval nixpkgs#flutter --no-eval-cache --eval-profiler flamegraphContext
Follow-up to #13220.
Current output is useful, but hard to interpret for end-users NixOS/nixpkgs#320528 (comment)
Add 👍 to pull requests you find important.
The Nix maintainer team uses a GitHub project board to schedule and track reviews.